local getYear = reload("getYear")

local date = {
    year = 1900,
    month = 12,
    day = 31,
    hour = 23,
    min = 59,
    sec = 59,
    isdst = true
}
---一年多少天
---@param sec integer|nil @时间
---@return integer @毫秒
return function (sec)
    date.year = getYear(sec or os.time())
    local time = os.time(date)
    local syearDay = os.date("%j", time)
    return tonumber(syearDay)
end
